package priv.hxm.jdbcUtils;


import java.util.HashMap;
import java.util.Scanner;


public class Inserts {

	public static void main(String[] args) {
		System.out.println("输入要插入的数值：");
		HashMap<String, Object> map = new HashMap<>();//把问题表和对应问题的id存入map中
		Scanner s = new Scanner(System.in);
		Scanner s1 = new Scanner(System.in);
		while(true){
		String k = s.next();
		int id = s1.nextInt();	
		map.put(k,id);
		boolean update = JDBCUtil.update("insert into answer(answer,a_id) values (?,?)",k,id );
		System.out.println(update);
		}

	}

}
